﻿CREATE TABLE [maint].[RestoreLog] (
    [DbName]        [sysname]      NOT NULL,
    [DeviceName]    NVARCHAR (128) NOT NULL,
    [FilePosition]  INT            NOT NULL,
    [Type]          INT            NOT NULL,
    [StartDate]     DATETIME       NOT NULL,
    [FinishDate]    DATETIME       NULL,
    [RestorePoint]  DATETIME       NULL,
    [RecoverStatus] BIT            NULL,
    [ErrorCode]     INT            NULL,
    [Output]        NVARCHAR (MAX) NULL,
    [RestoredBy]    [sysname]      NOT NULL,
    CONSTRAINT [PK_MaintRestoreLog] PRIMARY KEY CLUSTERED ([StartDate] ASC, [DbName] ASC, [DeviceName] ASC, [FilePosition] ASC, [Type] ASC)
);

